<?php
/**
 * 
 */
namespace app\manage\controller\agenttypelevelcoinconfig;

use app\manage\controller\Base;

class Api extends Base
{
    /**
     * 根据代理类型获取配置
     * @return [type] [description]
     */
    public function config_by_agent_type(){
        $params = $this->request->param();
        $id = isset($params['id'])?$params['id']:null;

        $data = model('agent_type_level_coin_config')::agentTypeConfig($id);

        return json(['code'=>1,'data'=>$data]);
    }

    public function row(){
        $params = $this->request->param();
        $id = isset($params['id'])?$params['id']:null;

        $data = model('agent_type_level_coin_config')::agentTypeLevelCoinConfigData($id);
        return json(['code'=>1,'data'=>$data]);
    }
    
}